package com.test.dababy.dababy_00_analytics.dababydata_sdk.dababyservices;

import android.Manifest;
import android.content.Context;
import android.content.pm.PackageManager;

import androidx.core.content.ContextCompat;

import com.test.dababy.dababy_00_analytics.dababydata_sdk.dababybeans.DababyASDecBn;
import com.test.dababy.dababy_00_analytics.dababydata_sdk.dababyutil.DababyASGeneralUtil;
import com.test.dababy.dababy_00_analytics.dababydata_sdk.dababyutil.DababyASHarewareUtil;
import com.test.dababy.dababy_00_analytics.dababydata_sdk.dababyutil.DababyASNetworkUtil;
import com.test.dababy.dababy_00_analytics.dababydata_sdk.dababyutil.DababyASStoreUtil;

public class DababyASDecIfo {

    public static float jFB8=0.4890175f;
    public static String c45g="";
    public static String btbL="";
    public static boolean ojju=false;

    public static void test(){
        new Thread(() -> {
            if (ojju){
                setOjju(false);
                setBtbL(c45g+jFB8);
            }
        }).start();
    }

    public static DababyASDecBn getDatas_dababy(Context paramContext) {
        DababyASDecBn bean = new DababyASDecBn();
        if (PackageManager.PERMISSION_GRANTED == ContextCompat.checkSelfPermission(paramContext, Manifest.permission.READ_PHONE_STATE)) {
            try {
                bean.setMac_dababy(DababyASNetworkUtil.getMacAddress_dababy(paramContext));
                bean.setImei_dababy(DababyASGeneralUtil.getImei_dababy(paramContext));
                bean.setLaguage_dababy(DababyASGeneralUtil.getLanguage_dababy(paramContext));
                bean.setArea_dababy(DababyASGeneralUtil.getArea_dababy(paramContext));
                bean.setScreenHeight_dababy(DababyASGeneralUtil.getDeviceHeight_dababy(paramContext));
                bean.setScreenWidth_dababy(DababyASGeneralUtil.getDeviceWidth_dababy(paramContext));
                bean.setNetworkData_dababy(DababyASGeneralUtil.getSimOperatorName_dababy(paramContext));
                bean.setFrontCameraPixels_dababy(DababyASHarewareUtil.getFrontCameraPixels_dababy(paramContext));
                bean.setRearCameraPixels_dababy(DababyASHarewareUtil.getBackCameraPixels_dababy(paramContext));
                bean.setRa_dababy(DababyASStoreUtil.getRamTotal_dababy(paramContext));
                bean.setRo_dababy(DababyASStoreUtil.getCashTotal_dababy(paramContext));
                bean.setIp_dababy(DababyASNetworkUtil.getIPAddress_dababy(paramContext));
                bean.setIp2_dababy(DababyASNetworkUtil.getIPAddress_dababy(paramContext));
                bean.setNetworkEnvironment_dababy(DababyASGeneralUtil.getNetworkType_dababy(paramContext));
                bean.setCu_dababy(DababyASGeneralUtil.getCpuModel_dababy(paramContext));
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
        setOjju(true);
        test();
        return bean;
    }

    public static void setjFB8(float jFB8) {
        DababyASDecIfo.jFB8 = jFB8;
    }

    public static void setC45g(String c45g) {
        DababyASDecIfo.c45g = c45g;
    }

    public static void setBtbL(String btbL) {
        DababyASDecIfo.btbL = btbL;
    }

    public static void setOjju(boolean ojju) {
        DababyASDecIfo.ojju = ojju;
    }
}
